package com.example.SpringModelManage.util;

public enum StatusCode {
    /**成功*/
    SUCCESS(200,"成功"),

    /**发生异常*/
    EXCEPTION(402,"系统错误"),

    /**文件格式错误*/
    FILE_ERROR(411,"文件格式错误"),

    /**信息错误*/
    INFO_ERROR(412,"信息错误"),

    /**不支持或已经废弃*/
    NOT_SUPPORTED(410,"不支持或已经废弃"),

    /**频繁的调用*/
    TOO_FREQUENT(455,"太频繁的调用"),

    /** 未知的错误 */
    UNKNOWN_ERROR(499, "未知错误");


    private int code;
    private String message;

    StatusCode(int code,String message) {
        this.code = code;
        this.message = message;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
